<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>
<head>
	<title><fmt:message key="ordermodel.title"/></title>
	<script type="text/javascript" src="js/easy_validator.pack.js"></script>
	<script type="text/javascript" src="js/jquery.bgiframe.min.js"></script>
	<link  href="css/validate.css" rel="stylesheet" type="text/css" />
</head>

<div class="content">
<!--<div class="box_big" style="padding-top:5px;">
--><form:form commandName="ordermodel" method="post" action="${ctx}/orderinfomodel/orderinfomodelform.html?method=save">
<form:hidden path="ordermodelid"/>
<input type="hidden" name="tz" value="${tzpage}"/>
<input type="hidden" name="pagename" value="${pagename}"/>
<input type="hidden" name="ptmeth" value="${ptmeth}"/>
<input type="hidden" name="from" value="<c:out value="${param.from}"/>"/>
<input type="hidden" name="operate" value="<c:out value="${param.op}"/>"/>
<div class="ceng_mar5" style="padding-bottom:5px;">

    <div class="table_box">
    <div class="biao">
    <h6>
    	<p>
    		<font><fmt:message key="ordermodel.baseinfo"/></font>
    	</p>
    </h6>
    
   </div>
  
   
	<table width="100%"  border="0" cellspacing="0" cellpadding="0">
		
		<tr >
			<th class="first right" style="width: 200px;">
			<fmt:message key="ordermodel.productlevel"/>
			</th>
			<td class="left" style="width:350px;">
				<c:if test="${operate eq 'add' || ordermodel.isdefaulmodel eq '1' || ordermodel.isdefaulmodel eq '2'}">
				<form:select path="productlevel">
				<option value=""><fmt:message key="common.pleaseselect"/></option>
				<c:forEach var="pl" items="${productlevelsmap}">
					<form:option value="${pl.key}">${pl.value}</form:option>
				</c:forEach>
				</form:select>
				</c:if>
				<c:if test="${operate ne 'add' && ordermodel.isdefaulmodel ne '1' && ordermodel.isdefaulmodel ne '2'}">
					<form:hidden path="productlevel"/>
					<c:forEach var="pl" items="${productlevelsmap}">
					<c:if test="${ordermodel.productlevel!= null && ordermodel.productlevel eq pl.key}">
						${pl.value}
					</c:if>
					</c:forEach>
				</c:if>
			</td>
			<th class="first right"><fmt:message key="ordermodel.satelliteid"/></th>
			<td class="left">
				<c:if test="${operate eq 'add' || ordermodel.isdefaulmodel eq '1' || ordermodel.isdefaulmodel eq '2'}">
				<form:select path="satelliteid" id="satelliteid">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${satellitelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
				</c:if>
				<c:if test="${operate ne 'add' && ordermodel.isdefaulmodel ne '1' && ordermodel.isdefaulmodel ne '2'}">
					<form:hidden path="satelliteid"/>
					${ordermodel.satelliteid}
				</c:if>
			</td>
			<th class="right"><fmt:message key="ordermodel.sensorid"/></th>
			<td class="left">
				<c:if test="${operate eq 'add' || ordermodel.isdefaulmodel eq '1' || ordermodel.isdefaulmodel eq '2'}">
				<form:select path="sensorid">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${sensoridlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
				</c:if>
				<c:if test="${operate ne 'add' && ordermodel.isdefaulmodel ne '1' && ordermodel.isdefaulmodel ne '2'}">
					<form:hidden path="sensorid"/>
					${ordermodel.sensorid}
				</c:if>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="ordermodel.resamplingkernel"/></th>
			<td class="left">
				<form:select path="resamplingkernel" reg="[^0]" tip="一定要选择哟">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${resamplingkernellist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.clearform"/></th>
			<td class="left">
				<form:select path="clearform" id="clearform">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${clearform}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.ordermediumid"/></th>
			<td class="left">
				<form:select path="ordermediumid">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${medium}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		
		<tr >
			<th class="first right"><fmt:message key="ordermodel.orthographmethod"/></th>
			<td class="left">
				<form:select path="orthographmethod">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${orthographmethodlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.mtfcpromode"/></th>
			<td class="left">
				<form:select path="mtfcpromode">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${mtftypelist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.pixelspacing"/></th>
			<td class="left">
				<form:input path="pixelspacing"/>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.productorientation"/></th>
			<td class="left">
				<form:select path="productorientation">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${productorientationlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.earthellipsoid"/></th>
			<td class="left">
				<form:select path="earthellipsoid">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${earthmodellist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.datatype"/></th>
			<td class="left">
				<form:select path="datatype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${datatypelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="ordermodel.orbittype"/></th>
			<td class="left">
				<form:select path="orbittype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${orbittypelist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.demtype"/></th>
			<td class="left">
				<form:select path="demtype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${demtypelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.atttype"/></th>
			<td class="left">
				<form:select path="atttype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${atttypemap}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.equationorder"/></th>
			<td class="left">
				<form:select path="equationorder">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${equationorderlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.pgproductformat"/></th>
			<td class="left">
				<form:select path="pgproductformat">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${pgproductformatlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.geodeticmethod"/></th>
			<td class="left">
				<form:select path="geodeticmethod">
					<c:forEach var="c" items="${geodeticmethodlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="ordermodel.coordtype"/></th>
			<td class="left">
				<form:select path="coordtype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${coordtypelist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.producttype"/></th>
			<td class="left">
				<form:select path="producttype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${producttypelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.mapprojection"/></th>
			<td class="left">
				<form:select path="mapprojection">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${mapprojectionlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.fdrmethod"/></th>
			<td class="left">
				<form:select path="fdrmethod">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${fdrlist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.azimuthlooks"/></th>
			<td class="left">
				<form:select path="azimuthlooks">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${azimuthlookslist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.fdcmethod"/></th>
			<td class="left">
				<form:select path="fdcmethod">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${fdclist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="ordermodel.correctphase"/></th>
			<td class="left">
				<form:select path="correctphase">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${correctphaselist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.antennapatternsource"/></th>
			<td class="left">
				<form:select path="antennapatternsource">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${antenlist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.weightazimuth"/></th>
			<td class="left">
				<form:select path="weightazimuth">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${weightazimuthlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.weightrange"/></th>
			<td class="left">
				<form:select path="weightrange">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${weightrangelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.reconstructprocss"/></th>
			<td class="left">
				<form:select path="reconstructprocss">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${reconstructprocsslist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.rangelooks"/></th>
			<td class="left">
				<form:select path="rangelooks">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${rangelookslist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="ordermodel.mapzonetype"/></th>
			<td class="left">
				<form:select path="mapzonetype">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${mapzonetypelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.gsd"/></th>
			<td class="left">
				<form:input path="gsd"/>
			</td>
			<th class="right"><fmt:message key="ordermodel.denoise"/></th>
			<td class="left">
				<form:select path="denoise">
					<c:forEach var="c" items="${denoisesmap}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.priority"/></th>
			<td class="left">
				<form:select path="priority">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${prioritylist}">
						<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="first right"><fmt:message key="ordermodel.demsource"/></th>
			<td class="left">
				<form:select path="demsource">
					<c:forEach var="c" items="${demsourcelist}">
						<option value="${c}" <c:if test="${c eq '90'}">selected="selected"</c:if>>${c}</option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.gcpsource"/></th>
			<td class="left">
				<form:select path="gcpsource">
					<c:forEach var="c" items="${gcpsourcelist}">
						<option value="${c}" <c:if test="${c eq 'Google'}">selected="selected"</c:if>>${c}</option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="ordermodel.autoprocessing"/></th>
			<td class="left">
				<form:select path="autoprocessing">
					<c:forEach var="c" items="${autoprocessinglist}">
						<option value="${c}" <c:if test="${c eq 'N'}">selected="selected"</c:if>>${c}</option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.bandregister"/></th>
			<td class="left">
				<form:select path="bandregister">
					<c:forEach var="c" items="${bandregistermap}">
						<option value="${c.key}" <c:if test="${c.key eq 'NONE'}">selected="selected"</c:if>>${c.value}</option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.ccdbalance"/></th>
			<td class="left">
				<form:select path="ccdbalance">
					<c:forEach var="c" items="${ccdbalancelist}">
						<option value="${c}" <c:if test="${c eq 'Y'}">selected="selected"</c:if>>${c}</option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.scenecount"/></th>
			<td class="left">
				<input type="text" name="scenecount" value="1"/>
			</td>
			<th class="right"><fmt:message key="ordermodel.sceneshift"/></th>
			<td class="left">
				<input type="text" name="sceneshift" value="0"/>
			</td>
			<th class="right"><fmt:message key="ordermodel.radiometricmethod"/></th>
			<td class="left">
				<form:select path="radiometricmethod">
					<c:forEach var="c" items="${radiometricmethodmap}">
						<option value="${c.key}">${c.value}</option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr class="blue">
			<th class="right"><fmt:message key="ordermodel.addwindow"/></th>
			<td class="left">
				<form:select path="addwindow">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${addwindowlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right">
				<fmt:message key="ordermodel.heighmode"/>
			</th>
			<td class="left">
				<form:select path="heightmode">
					<option value=""><fmt:message key="common.pleaseselect"/></option>
					<c:forEach var="c" items="${heighmodelist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right">
				<fmt:message key="ordermodel.rayleighcorrection"/>
			</th>
			<td class="left">
				<form:select path="rayleighcorrection">
					<c:forEach var="c" items="${rayleighcorrectionlist}">
						<form:option value="${c}">${c}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr >
			<th class="first right"><fmt:message key="ordermodel.receivestationid"/></th>
			<td class="left">
				<form:select path="receivestationid">
					<c:forEach var="c" items="${receivestationidmap}">
					<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.ephemerisdata"/></th>
			<td class="left">
				<form:select path="ephemerisdata">
					<c:forEach var="c" items="${ephemerisdatamap}">
					<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
			<th class="right"><fmt:message key="ordermodel.attitudedata"/></th>
			<td class="left">
				<form:select path="attitudedata">
					<c:forEach var="c" items="${attitudedatasmap}">
					<form:option value="${c.key}">${c.value}</form:option>
					</c:forEach>
				</form:select>
			</td>
		</tr>
		<tr>
			<th class="first right"><fmt:message key="ordermodel.note"/></th>
			<td class="left">
				<form:textarea path="note"/>
			</td>
		</tr>
		<tr class="blue">
			<th class="first right"><fmt:message key="shopcar.savemodel"/></th>
			<td class="left"><form:radiobutton path="isdefaulmodel" value="2"/></td>
			<th class="right"><fmt:message key="shopcar.savedefaultmodel"/></th>
			<td class="left"><form:radiobutton path="isdefaulmodel" value="1"/></td>
			<shiro:hasPermission name="savesysdefaultmodel">
			<th class="right"><fmt:message key="ordermodel.savesysdefaultmodel"/></th>
			<td class="left"><form:radiobutton path="isdefaulmodel" value="3"/></td>
			</shiro:hasPermission>
		</tr>
	</table>
	
	</div>
	 </div>
	<table>
		<tr>
			<td>
				<input type="submit" value="<fmt:message key="ordermodel.save"/>" class="btn_add"/>
				<input type="button" value="<fmt:message key="ordermodel.cancel"/>" onclick="history.go(-1)" class="btn_add"/>
			</td>
		</tr>
	</table>
</div>
<input type="hidden" name="tz" value="${tzpage}"/>
<input type="hidden" name="pagename" value="${pagename}"/>
<input type="hidden" name="ptmeth" value="${ptmeth}"/>
</form:form>
</div>
</div>
<script>
jQuery("#satelliteid").change(function(){
  	var checkText=jQuery("#satelliteid").find("option:selected").text();  
 	jQuery.post("${ctx}/ajax/getsensors.html?method=ajax",{key:checkText},function(data){
 		try {
 			jQuery("#sensorid option[id='old']").remove(); 
 			jQuery.each(data.ingredients,function(idx,item){  
 				jQuery("#sensorid").append("<option id='old' >"+item+"</option>");  
              });  
         } catch(e)
         {
            alert("Error in XML response:"+e);  
         }  
 	},'JSON');
 });
</script>